<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
    <th:block th:include="include :: header('修改交易对信息')" />
</head>
<body class="white-bg">
    <div class="wrapper wrapper-content animated fadeInRight ibox-content">
        <form class="form-horizontal m" id="form-symbol-edit" th:object="${mochaSymbol}">
            <input name="symbolId" th:field="*{symbolId}" type="hidden">
            <div class="form-group">    
                <label class="col-sm-3 control-label is-required">交易对名称：</label>
                <div class="col-sm-8">
                    <input name="symbol" th:field="*{symbol}" class="form-control" type="text" required>
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label is-required">价格精度：</label>
                <div class="col-sm-8">
                    <input name="priceScale" th:field="*{priceScale}" class="form-control" type="text" required>
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label is-required">数量精度：</label>
                <div class="col-sm-8">
                    <input name="quantityScale" th:field="*{quantityScale}" class="form-control" type="text" required>
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label is-required">最小交易金额：</label>
                <div class="col-sm-8">
                    <input name="minAmount" th:field="*{minAmount}" class="form-control" type="text" required>
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label is-required">最大交易金额：</label>
                <div class="col-sm-8">
                    <input name="maxAmount" th:field="*{maxAmount}" class="form-control" type="text" required>
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label is-required">Maker费率：</label>
                <div class="col-sm-8">
                    <input name="makerFeeRate" th:field="*{makerFeeRate}" class="form-control" type="text" required>
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label is-required">Taker费率：</label>
                <div class="col-sm-8">
                    <input name="takerFeeRate" th:field="*{takerFeeRate}" class="form-control" type="text" required>
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label is-required">交易对状态，当前是否可以进行交易：</label>
                <div class="col-sm-8">
                    <input name="state" th:field="*{state}" class="form-control" type="text" required>
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label is-required">Etf标识，0代表不是ETF，正负整数代表是ETF：</label>
                <div class="col-sm-8">
                    <input name="etfMark" th:field="*{etfMark}" class="form-control" type="text" required>
                </div>
            </div>
        </form>
    </div>
    <th:block th:include="include :: footer" />
    <script th:inline="javascript">
        var prefix = ctx + "system/symbol";
        $("#form-symbol-edit").validate({
            focusCleanup: true
        });

        function submitHandler() {
            if ($.validate.form()) {
                $.operate.save(prefix + "/edit", $('#form-symbol-edit').serialize());
            }
        }
    </script>
</body>
</html>